{% load static %}

  <footer>
    <div class="auto-inner clearfix">
      <dl class="fr code">
        <dd>
          <img src="{% static 'img/huadigongzhonghao.png' %}/" class="img-block" alt="官方公众号">
          <aside>
            官方公众号
          </aside>
        </dd>
      </dl>
      <div class="fl left">
        <nav>
          <a href="/">首页</a>
          <a href="/business">业务领域</a>
          <a href="/news">中标业绩</a>
          <a href="/honour">企业荣耀</a>
          <a href="/about_us">关于我们</a>
          <a href="/contact_us">联系我们</a>
        </nav>
        <div class="copyright">
          Copyright © 2024 河南省华帝建设工程有限公司 All Rights Reserved.
          <a href="https://beian.miit.gov.cn/" target="_blank">豫ICP备2022027810号-1</a>
        </div>
      </div>
    </div>
  </footer>
<script>
  // JavaScript to add active class based on current URL
  document.addEventListener('DOMContentLoaded', function() {
    var path = window.location.pathname;
      // console.log(path)
    var menuItems = document.querySelectorAll('.top-menu ul li aside a');

    menuItems.forEach(function(item) {
      if (item.getAttribute('href') === path) {
        item.parentElement.classList.add('active');
      }
    });
  });
</script>

<style>
  /* CSS for active state */
  .top-menu ul li.active aside a {
    color: #ff0000; /* Example active color, change as needed */
    font-weight: bold;
  }
</style>
